package com.basic.business.indicatorsFile.domain;

import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.basic.common.core.domain.BaseEntity;
import lombok.Getter;
import lombok.Setter;
import cn.idev.excel.annotation.ExcelProperty;
import cn.idev.excel.annotation.ExcelIgnoreUnannotated;
import com.basic.common.utils.StringUtils;
import com.basic.common.utils.uuid.ULID;

/**
 * 指标数据文件管理对象 t_indicators_file
 *
 * @author zhaoxy_jn@163.com
 * @date 2025-02-14
 */
@Getter
@Setter
@ExcelIgnoreUnannotated
public class TIndicatorsFile extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** id */
    private String id;

    /** 店铺id */
    @ExcelProperty(value = "店铺id")
    private String storeId;

    /** 文件名称 */
    @ExcelProperty(value = "文件名称")
    private String fileName;

    /** 上传日期 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ExcelProperty(value = "上传日期")
    private Date selectDate;

    /** 绝对路径 */
    @ExcelProperty(value = "绝对路径")
    private String absolutePath;

    /** 文件哈希值 */
    @ExcelProperty(value = "文件哈希值")
    private String fileHash;

    /** 文件指标类型 */
    private Integer type;

    /** 状态 正常：NORMAL 删除：DELETED 锁定：LOCKED */
    @ExcelProperty(value = "状态 正常：NORMAL 删除：DELETED 锁定：LOCKED")
    private String status;

    public void setId(String id) {
        this.id = StringUtils.isNotEmpty(id) ? id : ULID.getId();
    }

    //店铺名称
    private String storeName;
}
